package com.geektime.hello.controller;

import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("demo")
public class DemoController {

    @RequestMapping(value = "demo01", method = RequestMethod.GET)
    public String demo01(@RequestParam(value = "param", required = false, defaultValue = "hello") String param) {
        return param;
    }

    @GetMapping("demo02/{id}")
    public String demo02(@PathVariable("id") String id) {
        return null;
    }


}
